<?php

namespace common\models;

use Yii;
use \common\models\base\ApiPush as BaseApiPush;

/**
 * This is the model class for table "api_push".
 */
class ApiPush extends BaseApiPush
{
    const  push_platform_enums =['1'=>'android','2'=>'ios','3'=>'全部'];
    const  push_status_enums =['1'=>'等待执行','2'=>'已执行','3'=>'已取消'];
    /**
     * @inheritdoc
     */
    public function rules()
    {
        return array_replace_recursive(parent::rules(),
	    [
            [['push_platform', 'push_content', 'push_time', 'status','push_time'], 'required'],
            [[ 'status'], 'integer'],
            [['push_platform', 'push_content'], 'string', 'max' => 255],
//            [['lock'], 'default', 'value' => '0'],
//            [['lock'], 'mootensai\components\OptimisticLockValidator']
        ]);
    }
	
}
